//
// Created by Administrator on 2021/11/26.
//

#ifndef SPLATTING_DISPLAY_H
#define SPLATTING_DISPLAY_H

#include <GL/glut.h>
#include "Splatting.h"

const int iWidth = 520.0;
const int iHeight = 520.0;

class Display {
    static Display *currentInstance;

    Splatting *splatting;

    static void display_callback() {
        currentInstance->display();
    }

    void setup_display_callback() {
        currentInstance = this;
        glutDisplayFunc(display_callback);  //显示图像
    }

    void display();

public:
    Display(Splatting *s, int argc, char **argv);

    void exec();
};


#endif //SPLATTING_DISPLAY_H
